<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>QSculpt: GlslProgram Class Reference</title>

<link href="tabs.css" rel="stylesheet" type="text/css"/>
<link href="doxygen.css" rel="stylesheet" type="text/css" />

<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>

</head>
<body>
<div id="top"><!-- do not remove this div! -->


<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  
  
  <td style="padding-left: 0.5em;">
   <div id="projectname">QSculpt
   &#160;<span id="projectnumber">0.0.1a</span>
   </div>
   
  </td>
  
  
  
 </tr>
 </tbody>
</table>
</div>

<!-- Generated by Doxygen 1.7.5.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Main&#160;Page</span></a></li>
      <li><a href="namespaces.html"><span>Namespaces</span></a></li>
      <li class="current"><a href="annotated.html"><span>Classes</span></a></li>
      <li><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="annotated.html"><span>Class&#160;List</span></a></li>
      <li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
      <li><a href="functions.html"><span>Class&#160;Members</span></a></li>
    </ul>
  </div>
</div>
<div class="header">
  <div class="summary">
<a href="#pub-methods">Public Member Functions</a>  </div>
  <div class="headertitle">
<div class="title">GlslProgram Class Reference</div>  </div>
</div>
<div class="contents">
<!-- doxytag: class="GlslProgram" -->
<p><a href="class_glsl_program-members.html">List of all members.</a></p>
<table class="memberdecls">
<tr><td colspan="2"><h2><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr><td class="memItemLeft" align="right" valign="top">GLint&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a9b552a42b2728f184b6eda8654965dff">programID</a> () const </td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="a6342306833c2e4bcbd72332ffa180a2c"></a><!-- doxytag: member="GlslProgram::link" ref="a6342306833c2e4bcbd72332ffa180a2c" args="()" -->
bool&#160;</td><td class="memItemRight" valign="bottom"><b>link</b> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top"><a class="anchor" id="ae644dc0b0d90d974f5b9645a1c0532d2"></a><!-- doxytag: member="GlslProgram::buildLog" ref="ae644dc0b0d90d974f5b9645a1c0532d2" args="()" -->
std::string&#160;</td><td class="memItemRight" valign="bottom"><b>buildLog</b> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a43e99a0c03a56ae78fe54d7dd30b4d8e">attachShader</a> (<a class="el" href="class_glsl_shader.html">VertexShader</a> *shader)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#af69e7d8a34e31440c9bf3c6ed7a5cbf6">attachShader</a> (<a class="el" href="class_glsl_shader.html">FragmentShader</a> *shader)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a89c40e2d1ce78a995dfd5fe6b3e17771">useProgram</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a23f4e3fd64787e4e83d6409d056757ad">releaseProgram</a> ()</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a8be642fb207c3f247edc72c2c4e6b4c2">bindAttributeLocation</a> (GLuint index, const std::string &amp;name)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">GLint&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation</a> (const std::string &amp;name)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a198084b53bb385bf026111ed8c0b3d51">setUniform</a> (GLint index, int val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a89530fd92453a035991d9a190b45f114">setUniform</a> (GLint index, const Eigen::Vector2i &amp;val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a200a0a331d01d93b54fbbeea1b359932">setUniform</a> (GLint index, const Eigen::Vector3i &amp;val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#ae764feb35bf3a4676f174eee18f42f50">setUniform</a> (GLint index, const Eigen::Vector4i &amp;val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#ae0ece4e6a55fe9aa54611bbf4d924415">setUniform</a> (GLint index, float val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#acf73439c343a63fd62a57bd6262be51a">setUniform</a> (GLint index, const Eigen::Vector2f &amp;val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#aef060555bcc7a1fbb7b30923dc28fee9">setUniform</a> (GLint index, const Eigen::Vector3f &amp;val)</td></tr>
<tr><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="class_glsl_program.html#a8660f510a90eed6a135b1edc77e22530">setUniform</a> (GLint index, const Eigen::Vector4f &amp;val)</td></tr>
</table>
<hr/><h2>Member Function Documentation</h2>
<a class="anchor" id="a43e99a0c03a56ae78fe54d7dd30b4d8e"></a><!-- doxytag: member="GlslProgram::attachShader" ref="a43e99a0c03a56ae78fe54d7dd30b4d8e" args="(VertexShader *shader)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::attachShader </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_glsl_shader.html">VertexShader</a> *&#160;</td>
          <td class="paramname"><em>shader</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Add the shader to the current program.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">shader</td><td>shader to add to the program. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="af69e7d8a34e31440c9bf3c6ed7a5cbf6"></a><!-- doxytag: member="GlslProgram::attachShader" ref="af69e7d8a34e31440c9bf3c6ed7a5cbf6" args="(FragmentShader *shader)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::attachShader </td>
          <td>(</td>
          <td class="paramtype"><a class="el" href="class_glsl_shader.html">FragmentShader</a> *&#160;</td>
          <td class="paramname"><em>shader</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Add the shader to the current program.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">shader</td><td>shader to add to the program. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8be642fb207c3f247edc72c2c4e6b4c2"></a><!-- doxytag: member="GlslProgram::bindAttributeLocation" ref="a8be642fb207c3f247edc72c2c4e6b4c2" args="(GLuint index, const std::string &amp;name)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::bindAttributeLocation </td>
          <td>(</td>
          <td class="paramtype">GLuint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>name</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Bind attribute name to the program </p>

</div>
</div>
<a class="anchor" id="a9b552a42b2728f184b6eda8654965dff"></a><!-- doxytag: member="GlslProgram::programID" ref="a9b552a42b2728f184b6eda8654965dff" args="() const " -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">GLint GlslProgram::programID </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td> const</td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Name or id of the shader program as known to OpenGL. </p>

</div>
</div>
<a class="anchor" id="a23f4e3fd64787e4e83d6409d056757ad"></a><!-- doxytag: member="GlslProgram::releaseProgram" ref="a23f4e3fd64787e4e83d6409d056757ad" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::releaseProgram </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Makes the shader program to be no longer used. Switching to fixed pipeline.</p>
<p>Equivalent to calling glUseProgram(0). </p>

</div>
</div>
<a class="anchor" id="a198084b53bb385bf026111ed8c0b3d51"></a><!-- doxytag: member="GlslProgram::setUniform" ref="a198084b53bb385bf026111ed8c0b3d51" args="(GLint index, int val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a89530fd92453a035991d9a190b45f114"></a><!-- doxytag: member="GlslProgram::setUniform" ref="a89530fd92453a035991d9a190b45f114" args="(GLint index, const Eigen::Vector2i &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector2i &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a200a0a331d01d93b54fbbeea1b359932"></a><!-- doxytag: member="GlslProgram::setUniform" ref="a200a0a331d01d93b54fbbeea1b359932" args="(GLint index, const Eigen::Vector3i &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector3i &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ae764feb35bf3a4676f174eee18f42f50"></a><!-- doxytag: member="GlslProgram::setUniform" ref="ae764feb35bf3a4676f174eee18f42f50" args="(GLint index, const Eigen::Vector4i &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector4i &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="ae0ece4e6a55fe9aa54611bbf4d924415"></a><!-- doxytag: member="GlslProgram::setUniform" ref="ae0ece4e6a55fe9aa54611bbf4d924415" args="(GLint index, float val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">float&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="acf73439c343a63fd62a57bd6262be51a"></a><!-- doxytag: member="GlslProgram::setUniform" ref="acf73439c343a63fd62a57bd6262be51a" args="(GLint index, const Eigen::Vector2f &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector2f &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="aef060555bcc7a1fbb7b30923dc28fee9"></a><!-- doxytag: member="GlslProgram::setUniform" ref="aef060555bcc7a1fbb7b30923dc28fee9" args="(GLint index, const Eigen::Vector3f &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector3f &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a8660f510a90eed6a135b1edc77e22530"></a><!-- doxytag: member="GlslProgram::setUniform" ref="a8660f510a90eed6a135b1edc77e22530" args="(GLint index, const Eigen::Vector4f &amp;val)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::setUniform </td>
          <td>(</td>
          <td class="paramtype">GLint&#160;</td>
          <td class="paramname"><em>index</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">const Eigen::Vector4f &amp;&#160;</td>
          <td class="paramname"><em>val</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Set the value of uniform variable at location index.</p>
<p>The location is obtained by calling the function <a class="el" href="class_glsl_program.html#a6e393287fb3043d6896ace9c8c12df64">uniformLocation()</a></p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">index</td><td>location index of uniform to set the value. </td></tr>
    <tr><td class="paramname">val</td><td>value to set. </td></tr>
  </table>
  </dd>
</dl>

</div>
</div>
<a class="anchor" id="a6e393287fb3043d6896ace9c8c12df64"></a><!-- doxytag: member="GlslProgram::uniformLocation" ref="a6e393287fb3043d6896ace9c8c12df64" args="(const std::string &amp;name)" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">GLint GlslProgram::uniformLocation </td>
          <td>(</td>
          <td class="paramtype">const std::string &amp;&#160;</td>
          <td class="paramname"><em>name</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Get the location of a uniform variable.</p>
<p>Used after the program has been linked successfully, to retrieve the location of the uniform variable and be able to set a value to it.</p>
<dl><dt><b>Parameters:</b></dt><dd>
  <table class="params">
    <tr><td class="paramname">name</td><td>name of the uniform variable to look for.</td></tr>
  </table>
  </dd>
</dl>
<dl class="return"><dt><b>Returns:</b></dt><dd>the index of uniform in the program. -1 if there is an error. </dd></dl>

</div>
</div>
<a class="anchor" id="a89c40e2d1ce78a995dfd5fe6b3e17771"></a><!-- doxytag: member="GlslProgram::useProgram" ref="a89c40e2d1ce78a995dfd5fe6b3e17771" args="()" -->
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">void GlslProgram::useProgram </td>
          <td>(</td>
          <td class="paramname"></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div>
<div class="memdoc">
<p>Binds this program to the current context.</p>
<p>Equivalent to calling glUseProgram(). The program has to be compiled, otherwise it will throw an error. </p>

</div>
</div>
<hr/>The documentation for this class was generated from the following files:<ul>
<li>engine/include/<a class="el" href="_glsl_program_8h_source.html">GlslProgram.h</a></li>
<li>engine/src/GlslProgram.cpp</li>
</ul>
</div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerator</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>



<hr class="footer"/><address class="footer"><small>
Generated on Thu May 31 2012 16:19:52 for QSculpt by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
</a> 1.7.5.1
</small></address>

</body>
</html>
